Technical Q&As


QD3D 82 - DONT_NEED_DDRAW Preprocessor Explained (11-July-97)


Q I'm trying to build the Win32 sample from the QuickDraw 3D SDK using the MSVC++ 4.0 build environment. However, I keep getting the error: "can't find interface file ddraw.h". What's going on?

A You'll need to include the interface file "ddraw.h" in your build if you code makes use of the Q3DDSurfaceDrawContext_XXX routines. If you don't need Q3DDSurfaceDrawContext_XXX support in your application, define the preprocessor DONT_NEED_DDRAW in your application and the interface file "ddraw.h" won't be included in your build. An easy way to do this in MSVC++ 4.2 for a project is to go into the "Project Settings" window for the project (under the "Build" window, choose the "Settings" menu item), and in the "Preprocessor definitions" edit box add a definition for the preprocessor DONT_NEED_DDRAW.

However, if you do need Q3DDSurfaceDrawContext support in your application you'll need to actually get the "ddraw.h" interface file. This file can be found in MSVC++ 4.2, the Windows 32 SDK, or the Windows Game SDK.



-- Scott Kuechle
Worldwide Developer Technical Support

Technical Q&As
Previous Question | Contents | Next Question

To contact us, please use the Contact Us page.